﻿@model DLULearningNetworkModel.FeedComment
@{
    DLULearningNetworkModel.Account curUser = DLULearningNetwork.ActionFilterAttributes.RequireUserLogin.LoginUser;
}
<div class="row-comment" name="comment" feedCmtID ="@Model.FeedCommentID_u"  style="display: block;">
    @if (Model.ActiveAccount_u == curUser.AccountID_u
       || Model.FeedReference.Value.ActiveAccountID_u == curUser.AccountID_u
       || (Model.FeedReference.Value.CourseReference.Value != null && Model.FeedReference.Value.CourseReference.Value.AccountID_u == curUser.AccountID_u))
    {
        <div name="dcr_ID" style="display: none;">
            @*Disable/close comment row*@ <a name="deleteFeedComment" href="#" class="close"
                onclick="return false;" style="margin-right: 5px"></a>
        </div>
    }
    <div class="rowcomlt">
        <a class="avt" href="/UserPage/UserHome/@Model.AccountReference.Value.Nickname_s">
            @if (!string.IsNullOrEmpty(Model.AccountReference.Value.Avatar_s))
            {
                <img src="@Url.Content(Model.AccountReference.Value.Avatar_s.Replace("Original", "Small"))" alt="" />
            }
            else
            {
                <img src="@Url.Content("~/Content/Images/avatar.gif")" alt=""/>
            }
        </a>
    </div>
    <div class="rowcomrt">
        <a class="avt" style="color:green;" href="/UserPage/UserHome/@Model.AccountReference.Value.Nickname_s"><strong>@Model.AccountReference.Value.LastName_s
            @Model.AccountReference.Value.FirstName_s</strong></a> <span>@MvcHtmlString.Create(Model.Content_s.Replace("\\n", "<br>"))
               </span>
        <p>
            <span class="grey">@Html.TimePost(Model.CreateDate_dt)</span>
        </p>
    </div>
</div>
